﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;

namespace Arcana.Contract.Tests.Argument.Any.That.Is.LowerEqual
{
    [TestClass]
    public class ThanAttributeTest
    {
        [Arcana.Contract.Argument.Any.That.Is.LowerEqual.Than("arg", 5)]
        public static void Target_1(int[] arg)
        {
        }

        [TestMethod]
        [Owner("arcane_master")]
        [WorkItem(48)]
        [ExpectedException(typeof(ArgumentException))]
        public void ShouldThrowException()
        {
            Target_1(new int[] { 6, 7, 88 });
        }

        [TestMethod]
        [Owner("arcane_master")]
        [WorkItem(48)]
        public void ShouldPass()
        {
            Target_1(new int[] { });
            Target_1(new int[] { 6, 9, 5, 566 });
            Target_1(new int[] { 6, 9, 2, 444 });
        }
    }
}
